project(reactor)
cmake_minimum_required(VERSION 3.5)
set(REACTOR_DIR ./Reactor)
include_directories(${REACTOR_DIR})
set(REACTOR_SRC ${REACTOR_DIR}/event_demultiplexer.cc
${REACTOR_DIR}/event_demultiplexer.h
${REACTOR_DIR}/global.cc
${REACTOR_DIR}/global.h
${REACTOR_DIR}/reactor.cc
${REACTOR_DIR}/reactor.h
${REACTOR_DIR}/singleton.h
${REACTOR_DIR}/test_common.h
${REACTOR_DIR}/timeheap.h)

set(CLIENT ${REACTOR_SRC} reactor_client_test.cc)
set(SERVER ${REACTOR_SRC} reactor_server_test.cc)
set(CMAKE_CXX_COMPLIER g++)
set(CMAKE_BUILD_TYPE Debug)

set(BUILD_DIR ./build)
SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/build)
add_executable(reactor_client ${CLIENT})
add_executable(reactor_server ${SERVER})


